<html>
<head><meta charset="utf-8"><title>call graph · t-compiler · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/index.html">t-compiler</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html">call graph</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="154219975"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/154219975" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> blitzerr <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#154219975">(Jan 03 2019 at 04:49)</a>:</h4>
<p>Is there a way to generate a call graph for rustc or even better is there such a thing already online that can be navigated online ?</p>



<a name="157097393"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/157097393" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> pnkfelix <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#157097393">(Jan 29 2019 at 11:13)</a>:</h4>
<p>I'd love to know about what has been done here.</p>



<a name="157097396"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/157097396" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> pnkfelix <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#157097396">(Jan 29 2019 at 11:13)</a>:</h4>
<p>(if anything)</p>



<a name="157097398"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/157097398" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> pnkfelix <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#157097398">(Jan 29 2019 at 11:13)</a>:</h4>
<p>It seems like something that we could/should provide support for</p>



<a name="157097445"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/157097445" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nagisa <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#157097445">(Jan 29 2019 at 11:14)</a>:</h4>
<p>inlining needs call graph to work, so I would assume that it has its own implementation for that. And then there’s this monomorphisation collector thing, which technically traverses the call graph to find the necessary monomorphisations</p>



<a name="157097454"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/157097454" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nagisa <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#157097454">(Jan 29 2019 at 11:14)</a>:</h4>
<p>Not aware of anything that would be frameworky, but the same holds for e.g. dataflow.</p>



<a name="157098418"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/157098418" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> oli <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#157098418">(Jan 29 2019 at 11:34)</a>:</h4>
<p>japaric wrote <a href="https://github.com/japaric/cargo-call-stack" target="_blank" title="https://github.com/japaric/cargo-call-stack">https://github.com/japaric/cargo-call-stack</a> maybe we can use that?</p>



<a name="157098440"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/157098440" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> oli <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#157098440">(Jan 29 2019 at 11:35)</a>:</h4>
<p>I've also wondered if it would make sense to add a list of functions called by and calling the current function to rustdoc</p>



<a name="157098537"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/157098537" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> davidtwco <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#157098537">(Jan 29 2019 at 11:36)</a>:</h4>
<blockquote>
<p>I've also wondered if it would make sense to add a list of functions called by and calling the current function to rustdoc</p>
</blockquote>
<p>This could be super useful.</p>



<a name="157197498"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/157197498" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jake Goulding <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#157197498">(Jan 30 2019 at 15:57)</a>:</h4>
<p><em>useful</em>, yes but it seems like it's very likely to bloat the docs even more. <code>Iterator</code> docs already take 15s:</p>
<p><a href="/user_uploads/4715/u4GnYOxGEnVJEodunR90aLDg/pasted_image.png" target="_blank" title="pasted_image.png">pasted image</a></p>
<div class="message_inline_image"><a href="/user_uploads/4715/u4GnYOxGEnVJEodunR90aLDg/pasted_image.png" target="_blank" title="pasted image"><img src="/user_uploads/4715/u4GnYOxGEnVJEodunR90aLDg/pasted_image.png"></a></div>



<a name="157197757"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/157197757" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> QuietMisdreavus <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#157197757">(Jan 30 2019 at 16:00)</a>:</h4>
<p>tbh, i'm not totally sure how you could lay out such a "list of functions that call this" in the docs without it becoming absolutely huge, especially in the standard library</p>



<a name="157197794"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/157197794" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> QuietMisdreavus <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#157197794">(Jan 30 2019 at 16:01)</a>:</h4>
<p>plus, as shep referenced, we need to work to take information <em>out</em> of the page for Iterator, not add more &gt;_&gt;</p>



<a name="157198506"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/157198506" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> oli <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#157198506">(Jan 30 2019 at 16:10)</a>:</h4>
<p>There's no need to display everything on the main landing page of any type/trait/function/whatever</p>



<a name="157198516"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/157198516" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> oli <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#157198516">(Jan 30 2019 at 16:10)</a>:</h4>
<p>maybe we should just start splitting things out into linked pages</p>



<a name="157198525"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/157198525" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> oli <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#157198525">(Jan 30 2019 at 16:10)</a>:</h4>
<p>E.g. I rarely look at "types that implement this trait"</p>



<a name="157220466"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/call%20graph/near/157220466" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jake Goulding <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/call.20graph.html#157220466">(Jan 30 2019 at 20:47)</a>:</h4>
<p>Next you are going to say that pagination can also fix the problem of too much data on one page...</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>